﻿@using LunwenYun.Infrastructure.Entities.Entity;
@{
    Layout = "~/Views/Shared/_o_Main.cshtml";
    Periodical periodical = ViewBag.Periodical;
}
<div class="mini-layout graybg">
    <form id="form1" class="form-horizontal" method="post" action="/o/editorApply">
    <input type="hidden" name="id" value="@periodical.Id" />
    <fieldset>
        <legend style="font-weight: bold; color: #22a7b3; text-align: center">约稿人申请</legend>
        <div class="control-group">
            <label class="control-label">
                期刊名称</label>
            <div class="controls">
                <input type="text" readonly="readonly" placeholder="期刊名" value="@periodical.Name" class="span4" />
            </div>
        </div>
        <div class="control-group">
            <label class="control-label">
                约稿申明</label>
            <div class="controls">
                <textarea placeholder="填写约稿申明" name="about" class="span8" rows="8"></textarea>
            </div>
        </div>
        <hr />
        <div class="control-group">
            <div class="controls">
                <input type="submit" class="btn btn-large btn-info" value="提交申请" />
            </div>
        </div>
    </fieldset>
    </form>
</div>
@section tail{
    <script type="text/javascript" src="/Scripts/jquery.validate.js"></script>
    <script type="text/javascript" src="/Scripts/jquery.metadata.js"></script>
    <script type="text/javascript">
        $(function () {
            $('#form1').validate({
                errorClass: "help-inline",
                errorElement: "span",
                highlight: function (element, errorClass, validClass) {
                    $(element).parents('.control-group').addClass('error');
                },
                unhighlight: function (element, errorClass, validClass) {
                    $(element).parents('.control-group').removeClass('error');
                }
            });
        });
    </script>
}